#include "QTestRunner.h"

QTestRunner::QTestRunner()
    : m_bAllSuccess(true)
{
}

QTestRunner::~QTestRunner()
{
}

void QTestRunner::addTest(QObject *pTest)
{
    pTest->setParent(this);
    m_listTests.append(pTest);
}

void QTestRunner::run()
{
    foreach(QObject * qTest, m_listTests)
    {
        m_bAllSuccess |= (QTest::qExec(qTest, qApp->arguments()) == 0);
    }
}
